<?php
/**
 * 
 * 验证器
 * 
 * */
namespace app\member\validate;
use think\Validate;

class member_validate extends Validate
{
    //规则
    protected $rule = [
        'username'          => 'require|alphaNum',
        'password'          => 'require',
        'email'          => 'require|email',
        ];
    
    //自定义提示信息
    protected $message = [
        'username.require'       =>  '用户名不能为空!',
        'email.email'          => '邮箱不符合规范',
        'password.require'       =>  '密码不能为空!',
        'username.alphaNum'          => '用户名为字母或者数字',
        'email.require'          => '邮箱不能为空',
       ];
}